export enum FileType {
    ALL = 'all',
    DOCUMENT = 'document',
    IMAGE = 'image',
    AUDIO = 'audio',
    VIDEO = 'video',
    FOLDER = 'folder',
    ARCHIVE = 'archive',
    OTHER = 'other'
}

export interface FileItem {
    id: string;
    name: string;
    path: string;
    type: FileType;
    size: number;
    mimeType: string;
    extension: string;
    isFolder: boolean;
    createdAt: string;
    updatedAt: string;
    thumbnailUrl?: string;
    parentId?: string;
}

export interface FileListResponse {
    items: FileItem[];
    total: number;
    page: number;
    pageSize: number;
}

export interface FileListParams {
    page: number;
    pageSize: number;
    fileType?: FileType | null;
    keyword?: string;
    path?: string;
}

export interface FileUploadParams {
    files: File[];
    path: string;
}

export interface FolderCreateParams {
    name: string;
    path: string;
}

export interface FileTypeMenuItem {
    key: string;
    icon: React.ReactNode;
    label: string;
    type: FileType | null;
}

export interface FileToolbarProps {
    onSearch: (keyword: string) => void;
    onUpload: (files: File[], path: string) => void;
    onDelete: () => void;
    onCreateFolder: (folderName: string, path: string) => void;
    currentPath: string;
    selectedFiles: string[];
}

export interface FileSidebarProps {
    onFileTypeSelect: (type: FileType | null) => void;
    selectedFileType: FileType | null;
}

export interface FileListProps {
    files: FileItem[];
    loading: boolean;
    total: number;
    currentPage: number;
    pageSize: number;
    onPageChange: (page: number, size?: number) => void;
    onFileSelect: (fileIds: string[]) => void;
    selectedFiles: string[];
    onPathChange: (path: string) => void;
    currentPath: string;
    onDownload: (fileId: string) => void;
}

export interface FileIconProps {
    fileType: FileType;
    extension?: string;
    size?: number;
} 